﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:Filters="clr-namespace:Snipps.ViewModels.Filters" xmlns:Langs="clr-namespace:Snipps.Langs">


    <DataTemplate x:Key="SimpleCompletionListItemDataTemplate"
                  DataType="{x:Type Filters:CompletionListViewModel}">
        <Grid Background="Transparent">
            <TextBlock Name="txtName"
                       VerticalAlignment="Center"
                       Text="{Binding Name}" />
        </Grid>
        <DataTemplate.Triggers>
            <DataTrigger Binding="{Binding IsNew}"
                         Value="True">
                <Setter TargetName="txtName" Property="FontStyle" Value="Italic" />
                <Setter TargetName="txtName" Property="Text">
                    <Setter.Value>
                        <MultiBinding StringFormat="{}{0}: {1}">
                            <Binding Mode="OneTime"
                                     Source="{x:Static Langs:Lang.ListItemCreateNewTag}" />
                            <Binding FallbackValue=""
                                     Path="Name" />
                        </MultiBinding>
                    </Setter.Value>
                </Setter>
            </DataTrigger>
        </DataTemplate.Triggers>
    </DataTemplate>


</ResourceDictionary>